package com.po;

/**
 * AbstractOpCatalogRoleId entity provides the base persistence definition of
 * the OpCatalogRoleId entity. @author MyEclipse Persistence Tools
 */

public abstract class AbstractOpCatalogRoleId implements java.io.Serializable {

	// Fields

	private String cataId;
	private String roleId;

	// Constructors

	/** default constructor */
	public AbstractOpCatalogRoleId() {
	}

	/** full constructor */
	public AbstractOpCatalogRoleId(String cataId, String roleId) {
		this.cataId = cataId;
		this.roleId = roleId;
	}

	// Property accessors

	public String getCataId() {
		return this.cataId;
	}

	public void setCataId(String cataId) {
		this.cataId = cataId;
	}

	public String getRoleId() {
		return this.roleId;
	}

	public void setRoleId(String roleId) {
		this.roleId = roleId;
	}

	public boolean equals(Object other) {
		if ((this == other))
			return true;
		if ((other == null))
			return false;
		if (!(other instanceof AbstractOpCatalogRoleId))
			return false;
		AbstractOpCatalogRoleId castOther = (AbstractOpCatalogRoleId) other;

		return ((this.getCataId() == castOther.getCataId()) || (this
				.getCataId() != null
				&& castOther.getCataId() != null && this.getCataId().equals(
				castOther.getCataId())))
				&& ((this.getRoleId() == castOther.getRoleId()) || (this
						.getRoleId() != null
						&& castOther.getRoleId() != null && this.getRoleId()
						.equals(castOther.getRoleId())));
	}

	public int hashCode() {
		int result = 17;

		result = 37 * result
				+ (getCataId() == null ? 0 : this.getCataId().hashCode());
		result = 37 * result
				+ (getRoleId() == null ? 0 : this.getRoleId().hashCode());
		return result;
	}

}